const seq = require('sequelize');
const db = require('../config/database');
const Model = db.defineModel('xs_message', {
	userid: {
		type: seq.STRING(20),
		comment: '用户ID'
	},
	bookname: {
		type: seq.STRING(50),
		allowNull: true,
		comment: '小说名称',
		unique: true
	},
	bookhref: {
		type: seq.STRING(200),
		comment: '小说链接'
	},
	msgip: {
		type: seq.STRING(50),
		comment: '留言IP'
	},
	msgcontent: {
		type: seq.TEXT,
		comment: '留言内容'
	},
	msgreply: {
		type: seq.TEXT,
		comment: '回复内容'
	},
	createtime: {
		type: seq.BIGINT(13),
		comment: '创建时间'
	},
	updatetime: {
		type: seq.BIGINT(13),
		comment: '更新时间'
	}
});
module.exports = Model;